using System;
using System.Collections.Generic;
using System.Text;

namespace FaultTolerantWebService.Ui
{
    /// <summary>
    /// An exception to represent a cancellation
    /// </summary>
    public class CanceledException : ApplicationException
    {
        private bool byUser;

        public CanceledException()
        {
        }

        public CanceledException(string message)
            : base(message)
        {
        }
        public CanceledException(string message, bool byUser)
            : this(message)
        {
            this.byUser = byUser;
        }

        public CanceledException(string message, bool byUser, Exception innerException)
            : base(message, innerException)
        {
            ByUser = byUser;
        }

        public bool ByUser
        {
            get { return this.byUser; }
            set { this.byUser = value; }
        }
    }
}
